import request from '@/utils/request'


// 分页查询消息列表
export function queryMessageList(query) {
  return request({
    url: '/chat/page',
    method: 'get',
    params: query
  })
}

// 根据消息id查询消息
export function queryMessageById(messageId) {
  return request({
    url: '/chat/page/'+ messageId,
    method: 'get',
  })
}

// 根据消息id和表名删除消息
export function deleteMessageById(messageId) {
  return request({
    url: '/chat/deleteMessage',
    method: 'delete',
    data: messageId
  })
}



export const messageData = {
  queryMessageList: '/api/message/list',
  deleteMessage: '/api/message/delete',
  exportMessageDataList: '/api/message/export'
}
